package log;


import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.List;
import java.util.Objects;

/**
 * @author By YaoWen On  2015/7/14  16:10 ,QQ:2669932513
 *
 *  这些只是系统中用到的工具，
 */
public class Util {

    /**
     * 关于时间问题的类
     */
    public static class Time{
        public static String getTimeMs(){
            return toTimeString("yyyy-MM-dd-HH:mm:ss SSS");
        }

        public static String getTimeS(){
            return toTimeString("yyyy-MM-dd-HH:mm:ss");
        }

        public static String getTime(String format){
            return toTimeString(format);
        }

        private static String toTimeString(String format){
            String time = new SimpleDateFormat(format) .format(new Date() ).toString();
            return time;
        }
    } //end of "class Time"
}
